﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

using Microsoft.Practices.Prism.Modularity;
using Microsoft.Practices.Prism.Regions;
using Microsoft.Practices.Unity;

using RZD_maps.Modules.Transport.Views;

namespace RZD_maps.Modules.Transport
{
    public class TransportModule : IModule
    {
        private readonly IRegionManager regionManager;
        private readonly IUnityContainer container;

        public TransportModule(IUnityContainer container, IRegionManager regionManager)
        {
            this.container = container;
            this.regionManager = regionManager;
        }

        public void Initialize()
        {
            // Show the Orders Editor view in the shell's main region.
            this.regionManager.RegisterViewWithRegion("TransportRegion",
                                                       () => this.container.Resolve<View>());

        }

    }
}
